import { useRouteError } from "react-router-dom";
export { default as NotFound } from "./notFound";

export default function ErrorPage() {
  const error = useRouteError();

  return (
    <div id="error-page" style={{ padding: "16px" }}>
      <h1>Router Error Oops!</h1>
      <p>Sorry, an unexpected error has occurred.</p>
      <p>
        <i>{error.statusText || error.message}</i>
      </p>
    </div>
  );
}
